package com.tianya.portal.system.domain;

import com.tianya.portal.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.HashMap;
import java.util.Map;

/**
 * 文件信息
 *
 * @author tianya
 */
public class SysFile extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * 编号
     */
    private String id;

    /**
     * 附件名称
     */

    private String name;

    /**
     * 原始名称
     */

    private String originalName;

    /**
     * 附件链接
     */

    private String url;

    /**
     * 文件后缀名
     */

    private String fileSuffix;

    /**
     * 关联ID
     */

    private String linkId;

    /**
     * 关联模块
     */

    private String linkModule;

    /**
     * 关联类型
     */

    private String linkType;

    /**
     * 桶名称
     */

    private String bucketName;

    /**
     * 删除标志
     */

    private String deleteFlag;

    /**
     * 拓展参数
     */

    private Map<String, Object> extParams = new HashMap<String, Object>();

    public void setId(String id) {
        this.id = id;
    }

    public String getId() {
        return id;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setOriginalName(String originalName) {
        this.originalName = originalName;
    }

    public String getOriginalName() {
        return originalName;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getUrl() {
        return url;
    }

    public void setFileSuffix(String fileSuffix) {
        this.fileSuffix = fileSuffix;
    }

    public String getFileSuffix() {
        return fileSuffix;
    }

    public void setLinkId(String linkId) {
        this.linkId = linkId;
    }

    public String getLinkId() {
        return linkId;
    }

    public void setLinkModule(String linkModule) {
        this.linkModule = linkModule;
    }

    public String getLinkModule() {
        return linkModule;
    }

    public void setLinkType(String linkType) {
        this.linkType = linkType;
    }

    public String getLinkType() {
        return linkType;
    }

    public void setBucketName(String bucketName) {
        this.bucketName = bucketName;
    }

    public String getBucketName() {
        return bucketName;
    }

    public void setDeleteFlag(String deleteFlag) {
        this.deleteFlag = deleteFlag;
    }

    public String getDeleteFlag() {
        return deleteFlag;
    }

    public Map<String, Object> getExtParams() {
        return extParams;
    }

    public void setExtParams(Map<String, Object> extParams) {
        this.extParams = extParams;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("name", getName())
                .append("originalName", getOriginalName())
                .append("url", getUrl())
                .append("fileSuffix", getFileSuffix())
                .append("linkId", getLinkId())
                .append("linkModule", getLinkModule())
                .append("linkType", getLinkType())
                .append("bucketName", getBucketName())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .append("deleteFlag", getDeleteFlag())
                .toString();
    }
}
